/**
 * 
 */
package com.iwords.service.persistence;

import java.util.List;

import javax.ejb.Local;

import com.iwords.service.object.UserEntity;
import com.iwords.service.object.UserSysConfigEntity;

/**
 * @author       BOLIN.HBC 
 * @time         2011-3-10    
 * @description  User-Persistence       
 */
@Local
public interface UserPersistence {
	void create(UserEntity user);
	
	public boolean isContain(UserEntity user) ;

	public UserEntity findUser(UserEntity user) ;
	void edit(UserEntity user);

	void remove(UserEntity user);
	
	UserEntity find(UserEntity user);

	UserEntity find(Object id);


	List<UserEntity> findAll();

	List<UserEntity> findRange(int[] range);

	int count();
	
	public void updateCurrentLib(UserEntity user);
	
	public UserEntity findUserSysConfig(Long id);
	/**
	 * 获取该用户当天的某一配置
	 * 
	 * @param 	config
	 * 			查询配置信息
	 * @return	UserSysConfigEntity
	 *  		用户配置信息
	 */
	public UserSysConfigEntity getUserConfigByUserIdToday(UserSysConfigEntity config);
	
	
	/**
	 * 插入一条用户配置信息
	 * 
	 * @param config
	 *        用户配置信息
	 */
	public void insertUserConfig(UserSysConfigEntity config);
	/**
	 * 修改一条用户配置信息
	 * 
	 * @param config
	 *        用户配置信息
	 */
	public void updateUserConfig(UserSysConfigEntity config);
}
